package com.example.victory.entity.companyEntity;

import com.example.victory.swagger.model.AccountStatus;
import com.example.victory.swagger.model.AccountStatusEnum;
import lombok.Data;

@Data
public class AccountStatusEntity extends AccountStatus {
    private Integer khrq;

    public AccountStatus toAccountStatus() {
        if (this.khrq != null) {
            this.setStatus(AccountStatusEnum.OPEN);
            this.khrq = null;
        } else {
            this.setStatus(AccountStatusEnum.UNOPEN);
        }
        return this;
    }
}
